import utils.CUtil;
import vigenere.Vigenere;


public class main {

	/**
	 * @param args
	 */
	public static void main(String[] args) 
	{
		
		
		/* SIMPLE USE OF VIGENERE*/
		
		String arg="TOZZLTRBJEPEIIGI";
		Vigenere C=new Vigenere("RANK");
		System.out.println(C.decode(arg)); 
		//UNIT TESTS :)
		// test CUtil
		//String arg="ABCDEFGHIHKLMNOP";
		System.out.println("testing CUtil");
		System.out.println("arg in nums is: ");
		int[] a= CUtil.TextToNumbers(arg);
		for(int i=0;i<a.length;i++)
			System.out.print(a[i]+" ");
		System.out.println("\narg returned from conversion is: " + CUtil.NumbersToText(CUtil.TextToNumbers(arg)));
		
		//testing Vinegere
		Vigenere C1=new Vigenere("abcdefg");
		System.out.println("testing Vinegere");
		System.out.println("arg encoded with empty is: " + C1.encode(arg));
		System.out.println("arg decoded with empty is: " + C1.decode(arg));
		System.out.println("arg from conversion with empty is: " + C1.decode(C1.encode(arg)));
				
		
		

	}

}
